package com.cy.pj.common.advisor;

import org.aopalliance.intercept.MethodInterceptor;
import org.aopalliance.intercept.MethodInvocation;

public class LogAdvice implements MethodInterceptor {
    @Override
    public Object invoke(MethodInvocation invocation) throws Throwable {
        System.out.println("start:"+System.nanoTime());
        Object result = invocation.proceed();
        System.out.println("end:"+System.nanoTime());
        return result;
    }
}
